// Package orgInfo
// @Description: 普通组织的结构体
package orgInfo

type OrgInfo struct {
	// 组织基本信息
	OrgName  string // like "Org1"
	OrgMspId string // like "Org1MSP"
	// 节点Url
	PeersUrl []string // like "peer0.org1.example.com"
	// 普通用户
	NormalUsers []string // like "User1"
	// 管理员
	AdminUser string // like "Admin",默认只有一个admin用户
	// 锚节点配置文件路径
	AnchorFile string // like ./channel-artifacts/Org1MSPanchors.tx
}

//New 创建组织信息结构体
func New(orgName string, orgMspId string, peersUrl []string, normalUsers []string, adminUser string, anchorFilePath string) *OrgInfo {
	orgInfo := &OrgInfo{
		OrgName:     orgName,
		OrgMspId:    orgMspId,
		PeersUrl:    peersUrl,
		NormalUsers: normalUsers,
		AdminUser:   adminUser,
		AnchorFile:  anchorFilePath,
	}
	return orgInfo
}

// 方法太多，故分在不同文件
